package com.woniu.supermarket.mapper;

import com.woniu.supermarket.entity.Promotion;
import com.woniu.supermarket.vo.PromotionVo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PromotionMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Promotion record);

    Promotion selectByPrimaryKey(Integer id);

    List<Promotion> selectAll();

    int updateByPrimaryKey(Promotion record);

    List<PromotionVo> selectPromotionByPage(@Param(value = "code") String code, @Param(value = "status") int status);

}